Model run by trashe using Apollo 0.4.0 on R 4.5.3 for Linux. Please acknowledge the use of Apollo by citing Hess & Palma (2019) DOI 10.1016/j.jocm.2019.100170 www.ApolloChoiceModelling.com Model name : LC_no_covariates Model description : Simple LC model on Swiss route choice data, no covariates in class allocation model Model run at : 2026-11-02 22:00:03 Estimation method : bgw Estimation diagnosis : Relative function convergence (favorable) Optimisation diagnosis : Maximum found hessian properties : Negative definite maximum eigenvalue : -14.024112 reciprocal of condition number : 8.30697e-05 Number of individuals : 388 Number of rows in database : 3492 Number of modelled outcomes : 3492 Number of cores used : 2 Model without mixing LL(start) : -2067.4 LL (whole model) at equal shares, LL(0) : -2420.47 LL (whole model) at observed shares, LL(C) : -2420.39 LL(final, whole model) : -1562.08 Rho-squared vs equal shares : 0.3546 Adj.Rho-squared vs equal shares : 0.3505 Rho-squared vs observed shares : 0.3546 Adj.Rho-squared vs observed shares : 0.3509 AIC : 3144.16 BIC : 3205.74 LL(0,Class_1) : -2420.47 LL(final,Class_1) : -2513.86 LL(0,Class_2) : -2420.47 LL(final,Class_2) : -1769.69 Estimated parameters : 10 Time taken (hh:mm:ss) : 00:00:5.76 pre-estimation : 00:00:2.15 estimation : 00:00:3.43 post-estimation : 00:00:0.18 Iterations : 22 Unconstrained optimisation. Estimates: Estimate s.e. t.rat.(0) Rob.s.e. Rob.t.rat.(0) asc_1 -0.03522 0.047714 -0.7382 0.052970 -0.6649 asc_2 0.00000 NA NA NA NA beta_tt_a -0.21573 0.026447 -8.1571 0.050454 -4.2759 beta_tt_b -0.03754 0.005401 -6.9510 0.009742 -3.8532 beta_tc_a -0.79317 0.085615 -9.2644 0.119885 -6.6161 beta_tc_b -0.05105 0.013099 -3.8970 0.013426 -3.8021 beta_hw_a -0.05549 0.005634 -9.8493 0.008603 -6.4506 beta_hw_b -0.03454 0.003007 -11.4864 0.004578 -7.5456 beta_ch_a -2.77440 0.236531 -11.7296 0.312450 -8.8795 beta_ch_b -0.62690 0.072612 -8.6336 0.100287 -6.2511 delta_a 0.03374 0.175619 0.1921 0.198529 0.1700 delta_b 0.00000 NA NA NA NA Summary of class allocation for model component : Mean prob. Class_1 0.5084 Class_2 0.4916 Overview of choices for MNL model component Class_1: alt1 alt2 Times available 3492.00 3492.00 Times chosen 1734.00 1758.00 Percentage chosen overall 49.66 50.34 Percentage chosen when available 49.66 50.34 Overview of choices for MNL model component Class_2: alt1 alt2 Times available 3492.00 3492.00 Times chosen 1734.00 1758.00 Percentage chosen overall 49.66 50.34 Percentage chosen when available 49.66 50.34 Classical covariance matrix: asc_1 beta_tt_a beta_tt_b beta_tc_a beta_tc_b asc_1 0.002277 -9.019e-05 1.835e-05 -1.5628e-04 1.527e-05 beta_tt_a -9.019e-05 6.9946e-04 -3.562e-05 0.002034 -5.039e-06 beta_tt_b 1.835e-05 -3.562e-05 2.917e-05 -3.701e-05 5.158e-05 beta_tc_a -1.5628e-04 0.002034 -3.701e-05 0.007330 4.395e-05 beta_tc_b 1.527e-05 -5.039e-06 5.158e-05 4.395e-05 1.7158e-04 beta_hw_a -1.773e-06 6.539e-05 -5.645e-06 1.7681e-04 -1.544e-06 beta_hw_b 1.509e-06 -3.840e-06 4.801e-06 1.579e-05 5.228e-06 beta_ch_a -7.632e-06 0.004585 -6.642e-05 0.013643 3.1597e-04 beta_ch_b -3.435e-05 5.3414e-04 9.232e-05 0.002261 1.3901e-04 delta_a -4.603e-05 0.001769 1.4915e-04 0.006586 4.0673e-04 beta_hw_a beta_hw_b beta_ch_a beta_ch_b delta_a asc_1 -1.773e-06 1.509e-06 -7.632e-06 -3.435e-05 -4.603e-05 beta_tt_a 6.539e-05 -3.840e-06 0.004585 5.3414e-04 0.001769 beta_tt_b -5.645e-06 4.801e-06 -6.642e-05 9.232e-05 1.4915e-04 beta_tc_a 1.7681e-04 1.579e-05 0.013643 0.002261 0.006586 beta_tc_b -1.544e-06 5.228e-06 3.1597e-04 1.3901e-04 4.0673e-04 beta_hw_a 3.175e-05 -5.808e-06 5.9217e-04 -2.702e-05 4.454e-05 beta_hw_b -5.808e-06 9.043e-06 -2.112e-05 8.689e-05 1.2299e-04 beta_ch_a 5.9217e-04 -2.112e-05 0.055947 0.004558 0.019236 beta_ch_b -2.702e-05 8.689e-05 0.004558 0.005273 0.006950 delta_a 4.454e-05 1.2299e-04 0.019236 0.006950 0.030842 Robust covariance matrix: asc_1 beta_tt_a beta_tt_b beta_tc_a beta_tc_b asc_1 0.002806 -5.0159e-04 5.202e-05 -0.001168 4.991e-05 beta_tt_a -5.0159e-04 0.002546 -3.2500e-04 0.005494 -1.7699e-04 beta_tt_b 5.202e-05 -3.2500e-04 9.491e-05 -5.5108e-04 8.025e-05 beta_tc_a -0.001168 0.005494 -5.5108e-04 0.014372 -3.0200e-04 beta_tc_b 4.991e-05 -1.7699e-04 8.025e-05 -3.0200e-04 1.8025e-04 beta_hw_a -9.318e-06 2.1626e-04 -4.157e-05 3.3197e-04 -2.226e-05 beta_hw_b -1.081e-05 -5.484e-05 2.069e-05 -2.621e-05 1.421e-05 beta_ch_a -6.6834e-04 0.012303 -0.001462 0.024543 -4.9226e-04 beta_ch_b -6.0613e-04 0.001189 1.2803e-04 0.004771 1.0323e-04 delta_a -6.0862e-04 0.003718 -1.973e-05 0.011185 2.3560e-04 beta_hw_a beta_hw_b beta_ch_a beta_ch_b delta_a asc_1 -9.318e-06 -1.081e-05 -6.6834e-04 -6.0613e-04 -6.0862e-04 beta_tt_a 2.1626e-04 -5.484e-05 0.012303 0.001189 0.003718 beta_tt_b -4.157e-05 2.069e-05 -0.001462 1.2803e-04 -1.973e-05 beta_tc_a 3.3197e-04 -2.621e-05 0.024543 0.004771 0.011185 beta_tc_b -2.226e-05 1.421e-05 -4.9226e-04 1.0323e-04 2.3560e-04 beta_hw_a 7.401e-05 -2.274e-05 0.001454 -1.7679e-04 -9.218e-05 beta_hw_b -2.274e-05 2.095e-05 -3.3569e-04 2.1894e-04 2.6375e-04 beta_ch_a 0.001454 -3.3569e-04 0.097625 0.006565 0.026817 beta_ch_b -1.7679e-04 2.1894e-04 0.006565 0.010058 0.013081 delta_a -9.218e-05 2.6375e-04 0.026817 0.013081 0.039414 Classical correlation matrix: asc_1 beta_tt_a beta_tt_b beta_tc_a beta_tc_b asc_1 1.000000 -0.07147 0.07122 -0.03826 0.02444 beta_tt_a -0.071467 1.00000 -0.24941 0.89835 -0.01455 beta_tt_b 0.071218 -0.24941 1.00000 -0.08005 0.72907 beta_tc_a -0.038256 0.89835 -0.08005 1.00000 0.03919 beta_tc_b 0.024438 -0.01455 0.72907 0.03919 1.00000 beta_hw_a -0.006595 0.43884 -0.18553 0.36654 -0.02092 beta_hw_b 0.010518 -0.04828 0.29561 0.06134 0.13271 beta_ch_a -6.7629e-04 0.73301 -0.05200 0.67369 0.10198 beta_ch_b -0.009916 0.27814 0.23542 0.36366 0.14615 delta_a -0.005494 0.38092 0.15726 0.43805 0.17681 beta_hw_a beta_hw_b beta_ch_a beta_ch_b delta_a asc_1 -0.006595 0.01052 -6.7629e-04 -0.009916 -0.005494 beta_tt_a 0.438840 -0.04828 0.73301 0.278139 0.380921 beta_tt_b -0.185530 0.29561 -0.05200 0.235417 0.157260 beta_tc_a 0.366540 0.06134 0.67369 0.363656 0.438053 beta_tc_b -0.020924 0.13271 0.10198 0.146148 0.176807 beta_hw_a 1.000000 -0.34282 0.44434 -0.066051 0.045017 beta_hw_b -0.342816 1.00000 -0.02969 0.397950 0.232890 beta_ch_a 0.444344 -0.02969 1.00000 0.265398 0.463085 beta_ch_b -0.066051 0.39795 0.26540 1.000000 0.544991 delta_a 0.045017 0.23289 0.46308 0.544991 1.000000 Robust correlation matrix: asc_1 beta_tt_a beta_tt_b beta_tc_a beta_tc_b asc_1 1.00000 -0.1877 0.10080 -0.18388 0.07018 beta_tt_a -0.18769 1.0000 -0.66119 0.90829 -0.26129 beta_tt_b 0.10080 -0.6612 1.00000 -0.47183 0.61354 beta_tc_a -0.18388 0.9083 -0.47183 1.00000 -0.18763 beta_tc_b 0.07018 -0.2613 0.61354 -0.18763 1.00000 beta_hw_a -0.02045 0.4982 -0.49605 0.32188 -0.19275 beta_hw_b -0.04458 -0.2375 0.46394 -0.04776 0.23115 beta_ch_a -0.04038 0.7804 -0.48033 0.65523 -0.11735 beta_ch_b -0.11410 0.2351 0.13104 0.39682 0.07667 delta_a -0.05788 0.3712 -0.01020 0.46993 0.08839 beta_hw_a beta_hw_b beta_ch_a beta_ch_b delta_a asc_1 -0.02045 -0.04458 -0.04038 -0.11410 -0.05788 beta_tt_a 0.49823 -0.23745 0.78042 0.23506 0.37117 beta_tt_b -0.49605 0.46394 -0.48033 0.13104 -0.01020 beta_tc_a 0.32188 -0.04776 0.65523 0.39682 0.46993 beta_tc_b -0.19275 0.23115 -0.11735 0.07667 0.08839 beta_hw_a 1.00000 -0.57750 0.54076 -0.20492 -0.05397 beta_hw_b -0.57750 1.00000 -0.23471 0.47691 0.29022 beta_ch_a 0.54076 -0.23471 1.00000 0.20953 0.43232 beta_ch_b -0.20492 0.47691 0.20953 1.00000 0.65699 delta_a -0.05397 0.29022 0.43232 0.65699 1.00000 Settings and functions used in model definition: apollo_control -------------- Value modelName "LC_no_covariates" modelDescr "Simple LC model on Swiss route choice data, no covariates in class allocation model" indivID "ID" nCores "2" outputDirectory "output/" debug "FALSE" workInLogs "FALSE" seed "13" mixing "FALSE" HB "FALSE" noValidation "FALSE" noDiagnostics "FALSE" calculateLLC "TRUE" analyticHessian "FALSE" dropLoopExpansion "FALSE" dropRedefCheck "FALSE" panelData "TRUE" analyticGrad "TRUE" analyticGrad_manualSet "FALSE" overridePanel "FALSE" preventOverridePanel "FALSE" noModification "FALSE" Hessian routines attempted -------------------------- numerical jacobian of LL analytical gradient apollo_lcPars --------------- function (apollo_beta, apollo_inputs) { lcpars = list() lcpars[["beta_tt"]] = list(beta_tt_a, beta_tt_b) lcpars[["beta_tc"]] = list(beta_tc_a, beta_tc_b) lcpars[["beta_hw"]] = list(beta_hw_a, beta_hw_b) lcpars[["beta_ch"]] = list(beta_ch_a, beta_ch_b) V = list() V[["class_a"]] = delta_a V[["class_b"]] = delta_b classAlloc_settings = list(classes = c(class_a = 1, class_b = 2), utilities = V) lcpars[["pi_values"]] = apollo_classAlloc(classAlloc_settings) return(lcpars) } apollo_probabilities ---------------------- function (apollo_beta, apollo_inputs, functionality = "estimate") { apollo_attach(apollo_beta, apollo_inputs) on.exit(apollo_detach(apollo_beta, apollo_inputs)) P = list() mnl_settings = list(alternatives = c(alt1 = 1, alt2 = 2), avail = list(alt1 = 1, alt2 = 1), choiceVar = choice) for (s in 1:2) { V = list() V[["alt1"]] = asc_1 + beta_tt[[s]] * tt1 + beta_tc[[s]] * tc1 + beta_hw[[s]] * hw1 + beta_ch[[s]] * ch1 V[["alt2"]] = asc_2 + beta_tt[[s]] * tt2 + beta_tc[[s]] * tc2 + beta_hw[[s]] * hw2 + beta_ch[[s]] * ch2 mnl_settings$utilities = V P[[paste0("Class_", s)]] = apollo_mnl(mnl_settings, functionality) P[[paste0("Class_", s)]] = apollo_panelProd(P[[paste0("Class_", s)]], apollo_inputs, functionality) } lc_settings = list(inClassProb = P, classProb = pi_values) P[["model"]] = apollo_lc(lc_settings, apollo_inputs, functionality) P = apollo_prepareProb(P, apollo_inputs, functionality) return(P) }